home *** CD-ROM | disk | FTP | other *** search
- Path: rcp6.elan.af.mil!rscernix!root
- From: danpop@mail.cern.ch (Dan Pop)
- Newsgroups: gnu.misc.discuss,comp.std.c
- Subject: Re: Coding Standards are ignorant
- Date: 19 Mar 96 20:52:26 GMT
- Organization: CERN European Lab for Particle Physics
- Message-ID: <root.827268746@rscernix>
- References: <4gum82$14v4@info4.rus.uni-stuttgart.de> <KANZE.96Mar8125719@gabi.gabi-soft.fr> <danpop.826543744@rscernix> <4i829o$qbh@usenet.pa.dec.com> <4ikptb$er8@golem.phys.ndsu.NoDak.edu>
- NNTP-Posting-Host: ues5.cern.ch
- X-Newsreader: NN version 6.5.0 #7 (NOV)
-
- In <4ikptb$er8@golem.phys.ndsu.NoDak.edu> mooney@golem.phys.ndsu.NoDak.edu (Timothy Mooney) writes:
-
- >In article <4i829o$qbh@usenet.pa.dec.com>,
- >Norman Diamond <diamond@tbj.dec.com> wrote:
- >>In article <danpop.826543744@rscernix>, danpop@mail.cern.ch (Dan Pop) writes:
- >>>In <KANZE.96Mar8125719@gabi.gabi-soft.fr> kanze@gabi-soft.fr (J. Kanze) writes:
- >>>Does any of your compilers have a -iso option?
- >>
- >>At least one compiler has a -std option. That's the good news. The bad news
- >>is that it's documented (if an online manual page is a document :-) thus:
- >> -std Produce errors for constructions that are not compatible with the
- >> ANSI standard.
- >
- >DEC's cc for Digital Unix 3.2 has a -std option, and the man page does
- >mention the ISO standard.
-
- Does it? Not as far as I can see on my Digital Unix 3.2 box:
-
- -std[n]
- Have the compiler produce warnings for language constructs that are not
- standard in the language. The default is -std0.
-
- The -std flag enforces the ANSI C standard with popular extensions.
- and causes the macro __STDC__=0 to be passed to the preprocessor.
-
- The value n can be one of the following:
-
- 0 Enforce the K & R standard with some ANSI extensions, and causes
- the __STDC__ macro to be undefined.
-
- 1 Enforce the ANSI C standard and causes the macro __STDC__=1 to be
- passed to the preprocessor. Note that the -std1 flag also affects
- linker defined symbols. See the ld(1) reference page for more
- information.
-
- Dan
- --
- Dan Pop
- CERN, CN Division
- Email: danpop@mail.cern.ch
- Mail: CERN - PPE, Bat. 31 R-004, CH-1211 Geneve 23, Switzerland
-